import { defineStore } from 'pinia'
import { ref } from 'vue'
import type { WxPayJsapiParams } from '@/types/order'
export const usePay = defineStore('pay', () => {
  const payData = ref<WxPayJsapiParams>()

  const setPayData = (val: WxPayJsapiParams) => {
    payData.value = val
  }

  const getPayData = () => {
    return payData.value
  }

  return { getPayData, setPayData }
})
